<!DOCTYPE html>
<!--
@license
Copyright 2016 The TensorFlow Authors. All Rights Reserved.

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->

<html>
  <head>
    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>vz-distribution chart demo</title>
    <link rel="import" href="../tf-imports/polymer.html" />
    <link rel="import" href="vz-distribution-chart.html" />
    <link rel="import" href="../iron-demo-helpers/demo-snippet.html" />
    <link rel="import" href="../paper-styles/typography.html" />
    <style type="text/css">
      body {
        font-family: 'Roboto';
      }

      vz-distribution-chart {
        height: 400px;
      }
    </style>
  </head>
  <body>
    <h3>Simple distribution chart</h3>
    <script>
      var data = [
        [
          1716.2,
          0,
          [
            [0, 0.1],
            [668, 0.1],
            [1587, 0.1],
            [3085, 0.1],
            [5000, 0.1],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.1],
            [10000, 0.1],
          ],
        ],
        [
          1720.6,
          10,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.1],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.1],
            [10000, 0.1],
          ],
        ],
        [
          1724.9,
          20,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.1],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.1],
            [10000, 0.1],
          ],
        ],
        [
          1729.18,
          30,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.1],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.1],
            [10000, 0.1],
          ],
        ],
        [
          1733.55,
          40,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.1],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.1],
            [10000, 0.11],
          ],
        ],
        [
          1737.84,
          50,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.1],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.1],
            [10000, 0.1],
          ],
        ],
        [
          1742.35,
          60,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.1],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.1],
            [10000, 0.11],
          ],
        ],
        [
          1746.75,
          70,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.1],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.1],
            [10000, 0.11],
          ],
        ],
        [
          1751.15,
          80,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.1],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.1],
            [10000, 0.1],
          ],
        ],
        [
          1755.44,
          90,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.1],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.1],
            [10000, 0.1],
          ],
        ],
        [
          1759.99,
          100,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.1],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.1],
            [10000, 0.11],
          ],
        ],
        [
          1764.4,
          110,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.1],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.1],
            [10000, 0.11],
          ],
        ],
        [
          1768.7,
          120,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.1],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.1],
            [10000, 0.11],
          ],
        ],
        [
          1773.0,
          130,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.09],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.1],
            [10000, 0.11],
          ],
        ],
        [
          1777.57,
          140,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.1],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.1],
            [10000, 0.11],
          ],
        ],
        [
          1781.96,
          150,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.09],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.1],
            [10000, 0.11],
          ],
        ],
        [
          1786.34,
          160,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.09],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.11],
            [10000, 0.11],
          ],
        ],
        [
          1790.67,
          170,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.09],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.11],
            [10000, 0.11],
          ],
        ],
        [
          1794.96,
          180,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.09],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.11],
            [10000, 0.11],
          ],
        ],
        [
          1799.29,
          190,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.09],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.11],
            [10000, 0.11],
          ],
        ],
        [
          1803.68,
          200,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.09],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.11],
            [10000, 0.11],
          ],
        ],
        [
          1808.88,
          210,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.09],
            [6915, 0.1],
            [8413, 0.11],
            [9332, 0.11],
            [10000, 0.11],
          ],
        ],
        [
          1813.33,
          220,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.09],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.11],
            [10000, 0.11],
          ],
        ],
        [
          1817.66,
          230,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.09],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.11],
            [10000, 0.11],
          ],
        ],
        [
          1821.95,
          240,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.09],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.11],
            [10000, 0.11],
          ],
        ],
        [
          1826.97,
          250,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.09],
            [6915, 0.1],
            [8413, 0.11],
            [9332, 0.11],
            [10000, 0.11],
          ],
        ],
        [
          1831.64,
          260,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.09],
            [6915, 0.1],
            [8413, 0.1],
            [9332, 0.11],
            [10000, 0.11],
          ],
        ],
        [
          1836.01,
          270,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.09],
            [6915, 0.1],
            [8413, 0.11],
            [9332, 0.11],
            [10000, 0.11],
          ],
        ],
        [
          1840.31,
          280,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.09],
            [6915, 0.1],
            [8413, 0.11],
            [9332, 0.11],
            [10000, 0.11],
          ],
        ],
        [
          1844.63,
          290,
          [
            [0, 0.09],
            [668, 0.09],
            [1587, 0.09],
            [3085, 0.09],
            [5000, 0.09],
            [6915, 0.1],
            [8413, 0.11],
            [9332, 0.11],
            [10000, 0.11],
          ],
        ],
      ];
    </script>
    <demo-snippet>
      <template>
        <vz-distribution-chart id="demo"></vz-distribution-chart>
        <script>
          var elem = document.querySelector('#demo');
          elem.setVisibleSeries(['demo']);
          // The data format is strange. We don't expect you to use this chart.
          var xform = data.map(function(x) {
            var out = x[2];
            out.wall_time = x[0];
            out.step = x[1];
            return out;
          });
          elem.setSeriesData('demo', xform);
        </script>
      </template>
    </demo-snippet>
  </body>
</html>
